﻿Public Class frmSeleccionarReporte

    Dim reporte As Integer

    Private Sub Label1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label1.Click

    End Sub

    Private Sub btnAceptar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAceptar.Click

        reporte = lstbxSeleccionReporte.SelectedIndex
        Dim filePath As String
        If (reporte = 0) Then
            filePath = Application.StartupPath + "\reportes\ReporteVentasUltimoMes.rpt"
            frmVisualizarReporteVentas.CrystalReportViewerVentas.ReportSource = filePath
            frmVisualizarReporteVentas.Show()

        ElseIf (reporte = 1) Then
            filePath = Application.StartupPath + "\reportes\ReporteInventario.rpt"
            frmVisualizarReporteVentas.CrystalReportViewerVentas.ReportSource = filePath
            frmVisualizarReporteVentas.Show()

        ElseIf (reporte = 2) Then
            filePath = Application.StartupPath + "\reportes\ReporteProveedor.rpt"
            frmVisualizarReporteVentas.CrystalReportViewerVentas.ReportSource = filePath
            frmVisualizarReporteVentas.Show()

        ElseIf (reporte = 3) Then

        End If
        Me.Hide()
    End Sub

    Private Sub lstbxSeleccionReporte_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles lstbxSeleccionReporte.SelectedIndexChanged

    End Sub
End Class